<script setup>
import { reactive, toRaw } from 'vue';
const formState = reactive({
  name: '',
  describe: '',
});
const onSubmit = () => {
  console.log('submit!', toRaw(formState));
};
const labelCol = {
  style: {
    width: '150px',
  },
};
const wrapperCol = {
  span: 14,
};
</script>

<template>
  <a-form :model="formState" :label-col="labelCol" :wrapper-col="wrapperCol">
    <a-form-item label="表名称">
      <a-input v-model:value="formState.name" />
    </a-form-item>
    <a-form-item label="描述">
      <a-input v-model:value="formState.describe" />
    </a-form-item>
    <a-form-item :wrapper-col="{ span: 14, offset: 4 }">
      <a-button type="primary" @click="onSubmit">创建</a-button>
    </a-form-item>
  </a-form>
</template>

<style scoped>

</style>
